from os import path
from turtle import update
from sqlalchemy import Column, String, Integer, DateTime
from sqlalchemy.ext.declarative import declarative_base
base = declarative_base()


class RouteModel(base):
    __tablename__ = 'user'
    id = Column(Integer, nullable=False, primary_key=True, comment="自增ID")
    methods = Column(String(255), nullable=False, comment='访问方法')
    tags = Column(String(255), nullable=False, comment='标签')
    path = Column(String(255), nullable=False, comment='路径')
    endpoint = Column(String(255), nullable=False, comment='端点函数')
    update_time = Column(DateTime, nullable=False, comment='更新时间')
    description = Column(String(255), nullable=False, comment='描述')
    summary = Column(String(255), nullable=False, comment='摘要')
